package com.manage.competition.repository;

import com.manage.competition.entity.CompetitionReview;
import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.data.jpa.repository.JpaSpecificationExecutor;

import java.util.List;

/**
 * Create with IDEA
 *
 * @Author: gitee.com/KamisamaXX
 * @Date: Create in 21:39 2019/4/9
 * @Description:
 */
public interface CompetitionReviewRepository  extends JpaSpecificationExecutor<CompetitionReview>, JpaRepository<CompetitionReview,Long> {

    CompetitionReview findByUserIdAndCompetitionId(long userId,long competitionId);

    List<CompetitionReview> findByUserId(long userId);

    List<CompetitionReview> findByCompetitionId(long competitionId);
}
